﻿using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using Google.Protobuf;
using Google.Protobuf.Collections;
using Google.Protobuf.Reflection;

namespace EggLink.DanhengServer.Proto
{
	// Token: 0x0200051F RID: 1311
	[DebuggerDisplay("{ToString(),nq}")]
	public sealed class FeatureSwitchInfo : IMessage<FeatureSwitchInfo>, IMessage, IEquatable<FeatureSwitchInfo>, IDeepCloneable<FeatureSwitchInfo>, IBufferMessage
	{
		// Token: 0x170010F7 RID: 4343
		// (get) Token: 0x06003B4E RID: 15182 RVA: 0x000A3267 File Offset: 0x000A1467
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageParser<FeatureSwitchInfo> Parser
		{
			get
			{
				return FeatureSwitchInfo._parser;
			}
		}

		// Token: 0x170010F8 RID: 4344
		// (get) Token: 0x06003B4F RID: 15183 RVA: 0x000A326E File Offset: 0x000A146E
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageDescriptor Descriptor
		{
			get
			{
				return FeatureSwitchInfoReflection.Descriptor.MessageTypes[0];
			}
		}

		// Token: 0x170010F9 RID: 4345
		// (get) Token: 0x06003B50 RID: 15184 RVA: 0x000A3280 File Offset: 0x000A1480
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		MessageDescriptor IMessage.Descriptor
		{
			get
			{
				return FeatureSwitchInfo.Descriptor;
			}
		}

		// Token: 0x06003B51 RID: 15185 RVA: 0x000A3287 File Offset: 0x000A1487
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public FeatureSwitchInfo()
		{
		}

		// Token: 0x06003B52 RID: 15186 RVA: 0x000A329C File Offset: 0x000A149C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public FeatureSwitchInfo(FeatureSwitchInfo other) : this()
		{
			this.type_ = other.type_;
			this.switchList_ = other.switchList_.Clone();
			this.isAllClosed_ = other.isAllClosed_;
			this._unknownFields = UnknownFieldSet.Clone(other._unknownFields);
		}

		// Token: 0x06003B53 RID: 15187 RVA: 0x000A32E9 File Offset: 0x000A14E9
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public FeatureSwitchInfo Clone()
		{
			return new FeatureSwitchInfo(this);
		}

		// Token: 0x170010FA RID: 4346
		// (get) Token: 0x06003B54 RID: 15188 RVA: 0x000A32F1 File Offset: 0x000A14F1
		// (set) Token: 0x06003B55 RID: 15189 RVA: 0x000A32F9 File Offset: 0x000A14F9
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public FeatureSwitchType Type
		{
			get
			{
				return this.type_;
			}
			set
			{
				this.type_ = value;
			}
		}

		// Token: 0x170010FB RID: 4347
		// (get) Token: 0x06003B56 RID: 15190 RVA: 0x000A3302 File Offset: 0x000A1502
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public RepeatedField<FeatureSwitchParam> SwitchList
		{
			get
			{
				return this.switchList_;
			}
		}

		// Token: 0x170010FC RID: 4348
		// (get) Token: 0x06003B57 RID: 15191 RVA: 0x000A330A File Offset: 0x000A150A
		// (set) Token: 0x06003B58 RID: 15192 RVA: 0x000A3312 File Offset: 0x000A1512
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool IsAllClosed
		{
			get
			{
				return this.isAllClosed_;
			}
			set
			{
				this.isAllClosed_ = value;
			}
		}

		// Token: 0x06003B59 RID: 15193 RVA: 0x000A331B File Offset: 0x000A151B
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override bool Equals(object other)
		{
			return this.Equals(other as FeatureSwitchInfo);
		}

		// Token: 0x06003B5A RID: 15194 RVA: 0x000A332C File Offset: 0x000A152C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool Equals(FeatureSwitchInfo other)
		{
			return other != null && (other == this || (this.Type == other.Type && this.switchList_.Equals(other.switchList_) && this.IsAllClosed == other.IsAllClosed && object.Equals(this._unknownFields, other._unknownFields)));
		}

		// Token: 0x06003B5B RID: 15195 RVA: 0x000A338C File Offset: 0x000A158C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override int GetHashCode()
		{
			int num = 1;
			if (this.Type != FeatureSwitchType.FeatureSwitchNone)
			{
				num ^= this.Type.GetHashCode();
			}
			num ^= this.switchList_.GetHashCode();
			if (this.IsAllClosed)
			{
				num ^= this.IsAllClosed.GetHashCode();
			}
			if (this._unknownFields != null)
			{
				num ^= this._unknownFields.GetHashCode();
			}
			return num;
		}

		// Token: 0x06003B5C RID: 15196 RVA: 0x000A33F8 File Offset: 0x000A15F8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override string ToString()
		{
			return JsonFormatter.ToDiagnosticString(this);
		}

		// Token: 0x06003B5D RID: 15197 RVA: 0x000A3400 File Offset: 0x000A1600
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void WriteTo(CodedOutputStream output)
		{
			output.WriteRawMessage(this);
		}

		// Token: 0x06003B5E RID: 15198 RVA: 0x000A340C File Offset: 0x000A160C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalWriteTo(ref WriteContext output)
		{
			if (this.Type != FeatureSwitchType.FeatureSwitchNone)
			{
				output.WriteRawTag(8);
				output.WriteEnum((int)this.Type);
			}
			this.switchList_.WriteTo(ref output, FeatureSwitchInfo._repeated_switchList_codec);
			if (this.IsAllClosed)
			{
				output.WriteRawTag(24);
				output.WriteBool(this.IsAllClosed);
			}
			if (this._unknownFields != null)
			{
				this._unknownFields.WriteTo(ref output);
			}
		}

		// Token: 0x06003B5F RID: 15199 RVA: 0x000A3478 File Offset: 0x000A1678
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public int CalculateSize()
		{
			int num = 0;
			if (this.Type != FeatureSwitchType.FeatureSwitchNone)
			{
				num += 1 + CodedOutputStream.ComputeEnumSize((int)this.Type);
			}
			num += this.switchList_.CalculateSize(FeatureSwitchInfo._repeated_switchList_codec);
			if (this.IsAllClosed)
			{
				num += 2;
			}
			if (this._unknownFields != null)
			{
				num += this._unknownFields.CalculateSize();
			}
			return num;
		}

		// Token: 0x06003B60 RID: 15200 RVA: 0x000A34D8 File Offset: 0x000A16D8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(FeatureSwitchInfo other)
		{
			if (other == null)
			{
				return;
			}
			if (other.Type != FeatureSwitchType.FeatureSwitchNone)
			{
				this.Type = other.Type;
			}
			this.switchList_.Add(other.switchList_);
			if (other.IsAllClosed)
			{
				this.IsAllClosed = other.IsAllClosed;
			}
			this._unknownFields = UnknownFieldSet.MergeFrom(this._unknownFields, other._unknownFields);
		}

		// Token: 0x06003B61 RID: 15201 RVA: 0x000A3539 File Offset: 0x000A1739
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CodedInputStream input)
		{
			input.ReadRawMessage(this);
		}

		// Token: 0x06003B62 RID: 15202 RVA: 0x000A3544 File Offset: 0x000A1744
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalMergeFrom(ref ParseContext input)
		{
			uint num;
			while ((num = input.ReadTag()) != 0U)
			{
				if (num != 8U)
				{
					if (num != 18U)
					{
						if (num != 24U)
						{
							this._unknownFields = UnknownFieldSet.MergeFieldFrom(this._unknownFields, ref input);
						}
						else
						{
							this.IsAllClosed = input.ReadBool();
						}
					}
					else
					{
						this.switchList_.AddEntriesFrom(ref input, FeatureSwitchInfo._repeated_switchList_codec);
					}
				}
				else
				{
					this.Type = (FeatureSwitchType)input.ReadEnum();
				}
			}
		}

		// Token: 0x04001752 RID: 5970
		private static readonly MessageParser<FeatureSwitchInfo> _parser = new MessageParser<FeatureSwitchInfo>(() => new FeatureSwitchInfo());

		// Token: 0x04001753 RID: 5971
		private UnknownFieldSet _unknownFields;

		// Token: 0x04001754 RID: 5972
		public const int TypeFieldNumber = 1;

		// Token: 0x04001755 RID: 5973
		private FeatureSwitchType type_;

		// Token: 0x04001756 RID: 5974
		public const int SwitchListFieldNumber = 2;

		// Token: 0x04001757 RID: 5975
		private static readonly FieldCodec<FeatureSwitchParam> _repeated_switchList_codec = FieldCodec.ForMessage<FeatureSwitchParam>(18U, FeatureSwitchParam.Parser);

		// Token: 0x04001758 RID: 5976
		private readonly RepeatedField<FeatureSwitchParam> switchList_ = new RepeatedField<FeatureSwitchParam>();

		// Token: 0x04001759 RID: 5977
		public const int IsAllClosedFieldNumber = 3;

		// Token: 0x0400175A RID: 5978
		private bool isAllClosed_;
	}
}
